Carbon


GetGWorld

Header: QDOffscreen.h Carbon status: Supported

Saves the current graphics port (basic, color, or offscreen) and the current GDevice structure.

void GetGWorld (
    CGrafPtr *port, 
    GDHandle *gdh
);
port

On return, a pointer to the current graphics port in the port parameter. This parameter can return values of type GrafPtr, CGrafPtr, or GWorldPtr, depending on whether the current graphics port is a basic graphics port, color graphics port, or offscreen graphics world.

gdh

On return, a pointer to a handle to the GDevice structure for the current device.

DISCUSSION

After using GetGWorld to save a graphics port and a GDevice structure, use the SetGWorld function to restore them.

SPECIAL CONSIDERATIONS

The GetGWorld function may move or purge memory blocks in the application heap. Your application should not call this function at interrupt time.

AVAILABILITY

Supported in Carbon. Available in CarbonLib 1.0 and later when InterfaceLib 7.1 or later is installed. Exported by CarbonLib 1.0 and later and by InterfaceLib 7.1 and later.


© 2000 Apple Computer, Inc. — (Last Updated 4/14/2000)